#ifndef COLORSPACE_H
#define COLORSPACE_H

struct xyY
{
    float x;
    float y;
    float Y;
};

struct LED_Param
{
    struct xyY r;
    struct xyY g;
    struct xyY b;
};

void rgb2xyY(float *rgb,struct xyY *xyY);
void xyY2rgb(struct xyY *xyY,float *rgb);

void xyY2data(struct LED_Param *led,struct xyY *xyY,int16_t *data,int bit);

#endif
